################################################################
# Fulguro
# Copyright (C) 2004 Christophe Clienti
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2 of the License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the
# Free Software Foundation, Inc., 59 Temple Place - Suite 330,
# Boston, MA 02111-1307, USA.
################################################################

include ../Makefile.include

MOD =

.PHONY: $(MODULES_SWIG)


all : objects


doc:
	@for dir in $(MODULES_SWIG); do \
		echo -e "\n\033[1;34m*******************************************";\
		echo -e "\033[1;34m** Generating doc for $$dir ...\033[0m"; \
		echo -e "\033[1;34m*******************************************\033[0m";\
		for module in $(SWIG_EXPORT); do \
			(cd $$dir; ${MAKE} SWIG_LANG=$$module doc); \
			(cd $$dir; ${MAKE} SWIG_LANG=$$module clean); \
		done;\
	done

objects:
	@for dir in $(MODULES_SWIG); do \
		echo -e "\n\033[1;34m*******************************************";\
		echo -e "\033[1;34m** Wrapping $$dir ...\033[0m"; \
		echo -e "\033[1;34m*******************************************\033[0m";\
		for module in $(SWIG_EXPORT); do \
			(cd $$dir; ${MAKE} SWIG_LANG=$$module all); \
			(cd $$dir; ${MAKE} SWIG_LANG=$$module clean); \
		done;\
	done

install:
	cp -r ../lib/*Fulguro $(INSTALL_DIR_LIB)

clean :
	for dir in $(MODULES_SWIG); do \
		for module in $(SWIG_EXPORT); do \
			(cd $$dir; ${MAKE} SWIG_LANG=$$module clean); \
		done;\
	done
	rm -rf ../lib/*Fulguro